package com.epidemic.project.system.schedule.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.epidemic.project.system.schedule.mapper.SysScheduleMapper;
import com.epidemic.project.system.schedule.domain.SysSchedule;
import com.epidemic.project.system.schedule.service.ISysScheduleService;
import com.epidemic.common.utils.text.Convert;

/**
 * 课程Service业务层处理
 * 
 * @author sys
 * @date 2023-02-01
 */
@Service
public class SysScheduleServiceImpl implements ISysScheduleService 
{
    @Autowired
    private SysScheduleMapper sysScheduleMapper;

    /**
     * 查询课程
     * 
     * @param id 课程ID
     * @return 课程
     */
    @Override
    public SysSchedule selectSysScheduleById(Long id)
    {
        return sysScheduleMapper.selectSysScheduleById(id);
    }

    /**
     * 查询课程列表
     * 
     * @param sysSchedule 课程
     * @return 课程
     */
    @Override
    public List<SysSchedule> selectSysScheduleList(SysSchedule sysSchedule)
    {
        return sysScheduleMapper.selectSysScheduleList(sysSchedule);
    }

    /**
     * 新增课程
     * 
     * @param sysSchedule 课程
     * @return 结果
     */
    @Override
    public int insertSysSchedule(SysSchedule sysSchedule)
    {
        return sysScheduleMapper.insertSysSchedule(sysSchedule);
    }

    /**
     * 修改课程
     * 
     * @param sysSchedule 课程
     * @return 结果
     */
    @Override
    public int updateSysSchedule(SysSchedule sysSchedule)
    {
        return sysScheduleMapper.updateSysSchedule(sysSchedule);
    }

    /**
     * 删除课程对象
     * 
     * @param ids 需要删除的数据ID
     * @return 结果
     */
    @Override
    public int deleteSysScheduleByIds(String ids)
    {
        return sysScheduleMapper.deleteSysScheduleByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除课程信息
     * 
     * @param id 课程ID
     * @return 结果
     */
    @Override
    public int deleteSysScheduleById(Long id)
    {
        return sysScheduleMapper.deleteSysScheduleById(id);
    }
}
